﻿<UserControl x:Class="MicroBlogClient.UCPager"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="300">
    <Grid Style="{StaticResource PagerGridStyle}">
        <Grid.ColumnDefinitions>
            <ColumnDefinition/>
            <ColumnDefinition Width="40"/>
            <ColumnDefinition/>
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="1"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>
        <Border Height="3" Grid.ColumnSpan="3" BorderThickness="0" Background="#d4d8db" />
        <Button Grid.Row="1" IsEnabled="{Binding CanPreviousePageClick}"
                Click="btnFirstPage_Click"
                Style="{StaticResource PagerButtonStyle}" 
                HorizontalAlignment="Right"
                Grid.Column="0">
                <Button.Content>
                    <StackPanel Orientation="Horizontal">
                        <Image Source="/Resources/Images/commonimages/firstPageArrow.png" Height="10" Stretch="None" Width="10"/>
                        <TextBlock Text="回首页" FontSize="11"/>
                    </StackPanel>
                </Button.Content>
            </Button>
        <Button Grid.Row="1" 
                IsEnabled="{Binding CanPreviousePageClick}" 
                Style="{StaticResource PagerButtonStyle}" 
                Click="btnPreviousePage_Click"
                Width="20"
                Grid.Column="1">
                <Button.Content>
                   <Image Source="/Resources/Images/commonimages/leftArrow.png" VerticalAlignment="Center" Height="10" Stretch="None" Width="10"/>
                </Button.Content>
            </Button>
        <Button  Grid.Row="1"  
                 Style="{StaticResource PagerButtonStyle}" 
                 IsEnabled="{Binding CanNextPageClick}" 
                  Click="btnNextPage_Click"
                 Grid.Column="2" 
                 HorizontalAlignment="Left">
                <Button.Content>
                    <StackPanel Orientation="Horizontal">
                    <TextBlock Text="下一页" FontSize="11"/>
                        <Image Source="/Resources/Images/commonimages/rightArrow.png" Height="10" Stretch="None" Width="10"/>
                    </StackPanel>
                </Button.Content>
            </Button> 
        <!--<TextBlock>
            <Hyperlink x:Name="linkFirstPage" 
                       Click="linkFirstPage_Click" 
                       IsEnabled="{Binding CanPreviousePageClick}">
                <Run Text="返回首页"/></Hyperlink><Run Text="  "/>
            <Run Text=" "/>
            <Hyperlink x:Name="linkPreviousePage"
                       Click="linkPreviousePage_Click"
                       IsEnabled="{Binding CanPreviousePageClick}">
                <Run Text="上一页"/></Hyperlink><Run Text="  "/>
            <Run Text=" "/>
            <Hyperlink x:Name="linkNextPage" Click="linkNextPage_Click" IsEnabled="{Binding CanNextPageClick}">
                <Run Text="下一页"/></Hyperlink>
        </TextBlock>-->
    </Grid>
</UserControl>
